import React, { memo } from 'react';
import { SectionWrapper } from '@/views/home/c-cpns/home-sectionv3/style'
import SectionHeader from '@/components/section-header'
// import SectionRooms from '@/components/section-rooms'
import ScrollView from '@/base-ui/scroll-view'
import RoomItem from '@/components/room-item'

const HomeSectionV3 = memo((props) => {
  const {infoData} = props;
  return (
    <SectionWrapper>
      <SectionHeader title={ infoData.title } subtitle={ infoData.subtitle }></SectionHeader>
      <div className="room-list">
        <ScrollView>
          {
            infoData.list.map(item => {
              return <RoomItem itemData={ item } itemWidth="20%" key={ item.id }/>
            })
          }
        </ScrollView>
      </div>
    </SectionWrapper>
  );
});

export default HomeSectionV3;
